package com.xunqi.crm.service;

import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.xunqi.crm.pojo.User;
import org.springframework.cache.annotation.CacheConfig;
import org.springframework.cache.annotation.Cacheable;

import java.util.List;

public interface UserService {

    @Cacheable(value ="user::findUserByName" ,key = "#p0")
    User findUserByName(String name);

    @Cacheable(value ="user::login" ,key = "#p0")
    User login(String name,String pwd);

    IPage<User> selectPage(long currPage,long pageSize, Wrapper<User> wrapper);
}
